#ifndef LOGINWGT_H
#define LOGINWGT_H
#include<QStackedWidget>
#include <QWidget>
#include"httphelper.h"
class AppConfig;
class LoginWgt : public QWidget
{
    Q_OBJECT
public:
    explicit LoginWgt(QWidget *parent = nullptr);
public slots:
    void slot_Operator(const REQUESTTYPE tybe,bool result);
    void slot_MediaInfo(const QVector<QVariantMap> mediainfo);
protected:
    void mouseMoveEvent(QMouseEvent*event)override;
    void mousePressEvent(QMouseEvent *event) override;
    void mouseReleaseEvent(QMouseEvent *event) override;
private:
    void handleLogin(bool result);
    void handleRegister(bool result);
    void initLayout();
signals:
private:
        QPoint point;
    bool isPressed;
    AppConfig*appConfig=nullptr;
    QWidget*loginWgt;
    QWidget*registerWgt;
    QStackedWidget*stackedWgt;

};

#endif // LOGINWGT_H
